﻿using System;
using System.Collections.ObjectModel;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace System.Windows
{
    /// <summary>
    /// Implements a simple descriptor class for describing a sortable property and a sort direction.
    /// </summary>
    public class SortBinding
    {
        /// <summary>
        /// Initializes an instance of a <see cref="SortBinding"/> object.
        /// </summary>
        public SortBinding()
        {

        }

        /// <summary>
        /// Initializes an instance of a <see cref="SortBinding"/> object.
        /// </summary>
        /// <param name="fieldName">The field or property name to sort by</param>
        /// <param name="direction">The direction of the sorting</param>
        public SortBinding(string fieldName, SortDirections direction)
        {
            this.FieldName = fieldName;
            this.Direction = direction;
        }

        /// <summary>
        /// Gets/Sets the Field or Property name for the sort
        /// </summary>
        public string           FieldName { get; set; }

        /// <summary>
        /// Gete/Sets the direction of the sorting
        /// </summary>
        public SortDirections   Direction { get; set; }
    }

    /// <summary>
    /// Implements a collection of <see cref="SortBinding"/> objects.
    /// <remarks>
    /// NOTE: This class is observable by controls.
    /// </remarks>
    /// </summary>
    public class SortBindings : ObservableCollection<SortBinding>
    {
      
    }
}
